<%@ page contentType="text/html;charset=utf-8" %>
<%@page import="website.WebSiteAction"%>
<%@page import="common.serialization.XmlDataBean"%>
<%@page import="java.util.*"%>
<%@page import="org.apache.commons.lang.StringUtils"%>
<%
	XmlDataBean childRoot = WebSiteAction.getChildColumnByPid(request);
	String type = childRoot.getAttribute("type");//栏目：column, article：文章
	List<XmlDataBean> xmlList = childRoot.getChildXmlDataBeanList();
%>


<div class="com_left">
	<div class="com_left_title" style="background-image:url(${ctx}${menuColumn.LEFT_IMAGE_PATH});"><!--<h3>企业文化</h3>--></div>
    <div class="com_left_nav">
    	<!-- 循环第二级栏目开始 -->
    	<% 
    	for (XmlDataBean child : xmlList) {
    		String childId = child.getId();
    		String url = child.getAttribute("url");
    		if(StringUtils.isEmpty(url)) {
    			url = "/frontpage/main.jsp";
    		}
    	%>
        <a class="tt" href="${ctx}<%=url%>?menuId=${menuId}&columnId=<%=childId%>&type=<%=type%>"><%=child.getAttribute("text")%></a>
	        <% 
	        List<XmlDataBean> xmlList2 = child.getChildXmlDataBeanList();
	        if(xmlList2 != null && !xmlList2.isEmpty()) {
	        %>
	        <div class="com_left_nav_ch">
	        	<!-- 循环第三级栏目开始 -->
	        	<% 
		    	for (XmlDataBean child2 : xmlList2) {
		    		String childId2 = child2.getId();
		    		String url2 = child2.getAttribute("url");
		    		if(StringUtils.isEmpty(url2)) {
		    			url2 = "/frontpage/main.jsp";
		    		}
		    	%>
	        	<span><a href="${ctx}<%=url2%>?menuId=${menuId}&columnId=<%=childId2%>&type=<%=type%>"><%=child2.getAttribute("text")%></a></span>
	            <!-- 循环第三级栏目结束 -->
	            <%}%>
	        </div>
        <%	}
    	}
        %>
        <!-- 循环第二级栏目结束 -->
    </div>
    <div class="com_project">

    </div>
</div>